import Mock from 'mockjs';

const menuMock = Mock.mock(
  '/api/menus', 'post', (req, res) => {
    return {
      "ret": {
        "ok": true,
        "code": 200,
        "msg": "success"
      },
      "page": null,
      "data": [
        {
          "id": 1,
          "name": "运维监控",
          "url": "/devmgnt",
          "icon": "dns",
          "color": "warning",
          "subItems": [
            {
              "name": "Dashboard",
              "url": "/dashboard",
              "icon": "tv",
              "color": "secondary"
            },
            {
              "name": "设备管理",
              "url": "/devmgnt",
              "icon": "dns",
              "color": "warning",
              "subItems": [
                {
                  "name": "设备列表",
                  "url": "/devmgnt",
                  "icon": "dns",
                  "color": "warning"
                },
                {
                  "name": "GIS拓扑",
                  "url": "/sub/sys/pkg",
                  "icon": "assignment",
                  "color": "info"
                },
                {
                  "name": "告警分析",
                  "url": "/devmgnt",
                  "icon": "devices_other",
                  "color": "warning"
                },
                {
                  "name": "故障跟踪",
                  "url": "/sub/auth/user",
                  "icon": "people",
                  "color": "blue"
                }
              ]
            },
            {
              "name": "GIS拓扑",
              "url": "/sub/sys/pkg",
              "icon": "assignment",
              "color": "info"
            },
            {
              "name": "告警分析",
              "url": "/devmgnt",
              "icon": "devices_other",
              "color": "warning"
            },
            {
              "name": "故障跟踪",
              "url": "/sub/auth/user",
              "icon": "people",
              "color": "blue"
            },
            {
              "name": "系统管理",
              "url": "/sys",
              "icon": "verified_user",
              "color": "orange",
              "subItems":[
                {
                  "name": "用户管理",
                  "url": "/auth/user",
                  "icon": "devices_other",
                  "color": "warning"
                },
                {
                  "name": "角色管理",
                  "url": "/auth/role",
                  "icon": "people",
                  "color": "blue"
                },
                {
                  "name": "分组管理",
                  "url": "/sys/group",
                  "icon": "verified_user",
                  "color": "orange"
                },
                {
                  "name": "资源管理",
                  "url": "/sys/pkg",
                  "icon": "assignment",
                  "color": "info"
                }
              ]
            }
          ]
        },
        {
          "id": 2,
          "name": "云++",
          "url": "/sys/pkg",
          "icon": "assignment",
          "color": "info",
          "subItems": [
            {
              "name": "设备模型",
              "url": "/dev/defined",
              "icon": "verified_user",
              "color": "orange"
            },
            {
              "name": "云接口",
              "url": "/sys/group",
              "icon": "devices_other",
              "color": "warning"
            },
            {
              "name": "云应用",
              "url": "/sys/group",
              "icon": "assignment",
              "color": "info"
            },
            {
              "name": "云统计",
              "url": "/auth/user",
              "icon": "people",
              "color": "blue"
            },
            {
              "name": "云分析",
              "url": "/auth/role",
              "icon": "verified_user",
              "color": "orange"
            }
          ]
        },
        {
          "id": 3,
          "name": "端++",
          "url": "/sys/group",
          "icon": "devices_other",
          "color": "warning",
          "subItems": [
            {
              "name": "可视化编程",
              "url": "/sys/group",
              "icon": "assignment",
              "color": "info"
            },
            {
              "name": "运行程序",
              "url": "/sys/group",
              "icon": "devices_other",
              "color": "warning"
            },
            {
              "name": "软件补丁",
              "url": "/sys/group",
              "icon": "people",
              "color": "blue"
            }
          ]
        },
        {
          "id": 4,
          "name": "解决方案",
          "url": "/auth/user",
          "icon": "people",
          "color": "blue",
          "subItems": [
            {
              "name": "智慧社区",
              "url": "/sys/group",
              "icon": "assignment",
              "color": "info"
            },
            {
              "name": "智慧城市",
              "url": "/sys/group",
              "icon": "devices_other",
              "color": "warning"
            },
            {
              "name": "桥梁监控",
              "url": "/auth/user",
              "icon": "people",
              "color": "blue"
            },
            {
              "name": "地灾预警",
              "url": "/auth/role",
              "icon": "verified_user",
              "color": "orange"
            },
            {
              "name": "农业大棚",
              "url": "/sys/group",
              "icon": "assignment",
              "color": "info"
            },
            {
              "name": "用电安全",
              "url": "/sys/group",
              "icon": "devices_other",
              "color": "warning"
            }
          ]
        },
        {
          "id": 5,
          "name": "系统管理",
          "url": "/auth/role",
          "icon": "verified_user",
          "color": "orange",
          "subItems": [
            {
              "name": "用户权限",
              "url": "/sys/group",
              "icon": "assignment",
              "color": "info"
            },
            {
              "name": "系统日志",
              "url": "/sys/group",
              "icon": "devices_other",
              "color": "warning"
            },
            {
              "name": "运维监控",
              "url": "/auth/user",
              "icon": "people",
              "color": "blue"
            },
            {
              "name": "运维升级",
              "url": "/auth/role",
              "icon": "verified_user",
              "color": "orange"
            }
          ]
        }
      ]
    }
  })

export default menuMock
